package com.aaa.system.controller;

import com.aaa.entity.LoginLog;
import com.aaa.system.service.LoginLogService;
import com.aaa.vo.Result;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author 崔灿
 * @Date 2023/02/28 20:28
 * @ClassName LoginLogController
 * @Description
 * @Version 1.0
 */

@Api(value = "/system/addLoginLog", tags = {"登录日志"})
@RestController
@RequestMapping("/system/addLoginLog")
public class LoginLogController {

    @Autowired
    private LoginLogService loginLogService;

    @ApiImplicitParams({
            @ApiImplicitParam(paramType = "body", dataType = "LoginLog", name = "loginLog", value = "", required = true)
    })
    @ApiOperation(value = "", notes = "", httpMethod = "POST")
    @PostMapping(value = "/addLoginLog")
    public Result addLoginLog(@RequestBody LoginLog loginLog) {
        return loginLogService.addLoginLog(loginLog);
    }
}
